package org.vestbjergbyggecenter.Test;

import static org.junit.Assert.*;

import org.junit.Test;
import org.vestbjergbyggecenter.Model.Person;

public class TestPerson {

	@Test
    public void testSetId()
    {
        Person person1 = new Person(1,"Ivo",7301388,"Elisevej",9203324, "Aalborg","3434343434");
        person1.setId(1);
        assertEquals(1, person1.getId());
    }

 @Test
    public void testGetId()
    {
        Person person1 = new Person(3,"Ivo",7301388,"Elisevej",9203324, "Aalborg","3434343434");
        person1.setId(3);
        assertEquals(3, person1.getId());
    } 
 
 
    @Test
    public void testSetName()
    {
        Person person1 = new Person(1,"Ivo",7301388,"Elisevej",9203324, "Aalborg","3434343434");
        person1.setName("Ivo");
        assertEquals("Ivo",person1.getName());
    }
 
    @Test
    public void testGetName()
    {
        Person person1 = new Person(1,"Ivo",7301388,"Elisevej",9203324, "Aalborg","3434343434");
        person1.setName("Ivo");
        assertEquals("Ivo",person1.getName());
    }
    
    @Test
    public void testSetAddress()
    {
        Person person1 = new Person(1,"Ivo",7301388,"Elisevej",9203324, "Aalborg","3434343434");
        person1.setAddress("Elisevej");
        assertEquals("Elisevej",person1.getAddress());
    }
    
    
    @Test
    public void testGetAddress()
    {
        Person person1 = new Person(1,"Ivo",7301388,"Elisevej",9203324, "Aalborg","3434343434");
        person1.setAddress("Elisevej");
        assertEquals("Elisevej",person1.getAddress());
    }
 
 
    @Test
    public void testSetPostalcode()
    {
        Person person1 = new Person(1,"Ivo",7301388,"Elisevej",9203324, "Aalborg","3434343434");
        person1.setPostalCode(1234);
        assertEquals(1234,person1.getPostalCode());
    }
    
    @Test
    public void testGetPostalcode()
    {
        Person person1 = new Person(1,"Ivo",7301388,"Elisevej",9203324, "Aalborg","3434343434");
        person1.setPostalCode(1234);
        assertEquals(1234,person1.getPostalCode());
    }
    
    @Test 
    public void testSetCity()
    {
        Person person1 = new Person(1,"Ivo",7301388,"Elisevej",9203324, "Aalborg","3434343434");
        person1.setCity("Aalborg");
        assertEquals("Aalborg",person1.getCity());
    }
    
    
    @Test
    public void testGetCity()
    {
        Person person1 = new Person(1,"Ivo",7301388,"Elisevej",9203324, "Aalborg","3434343434");
        person1.setCity("Aalborg");
        assertEquals("Aalborg",person1.getCity());
    } 
    
    
    @Test
    public void testSetPhone()
    {
        Person person1 = new Person(1,"Ivo",7301388,"Elisevej",9203324, "Aalborg","3434343434");
        person1.setPhone("3434343434");
        assertEquals("3434343434",person1.getPhone());
    }
    
    
    
    @Test
    public void testGetPhone()
    {
        Person person1 = new Person(1,"Ivo",7301388,"Elisevej",9203324, "Aalborg","3434343434");
        person1.setPhone("3434343434");
        assertEquals("3434343434",person1.getPhone());
    }

    @Test
    public void testSetCPR()
    {
        Person person1 = new Person(1,"Ivo",7301388,"Elisevej",9203324, "Aalborg","3434343434");
        person1.setCPR(7301388);
        assertEquals(7301388,person1.getCPR());
    }
    
    
    
    @Test
    public void testGetCPR()
    {
        Person person1 = new Person(1,"Ivo",7301388,"Elisevej",9203324, "Aalborg","3434343434");
        person1.setCPR(7301388);
        assertEquals(7301388,person1.getCPR());
    }
}
